<!doctype html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="chrome=1">
    <meta name="viewport" content="initial-scale=1.0, user-scalable=no, width=device-width">
    <style type="text/css">
      body,html,#container{
        height: 100%;
        margin: 0px;
        font: 12px Helvetica, 'Hiragino Sans GB', 'Microsoft Yahei', '微软雅黑', Arial;
      }
      .info-title{
        color: #43abeb;
        font-size: 16px;
        line-height: 26px;
        padding: 0px 0 0 6px;
        font-weight: lighter;
        letter-spacing: 1px;
        font-weight: bold;
      }
      .info-content{
        padding: 4px;
        color: #666666;
        line-height: 1.5em;
        font-size: 15px;
      }
      .info-content img{
        float: left;
        margin: 3px;
        margin-right: 10px;
      }
    </style>
    <title>驾校地址</title>
  </head>
  <body>
   <div id="container" tabindex="0"></div>
   
   <script type="text/javascript" src="../js/jquery-1.10.1.min.js" ></script>
    <script type="text/javascript" src="../js/get_url_parameter.js" ></script>
    <script>
    	var longitude=request("longitude")
    	var latitude=request("latitude")
    	var area_str=request("area_str")
    </script>
<script type="text/javascript" src="https://webapi.amap.com/maps?v=1.4.0&key=0d1d97cc66316b3fc35b0fca893f0d5b"></script>
   <script type="text/javascript">
    var map = new AMap.Map('container',{
            resizeEnable: true,
            zoom: 13,
            center: [longitude, latitude]
    });
    var marker = new AMap.Marker({
            position: [longitude, latitude],
//          animation:"AMAP_ANIMATION_BOUNCE"
    });
    marker.setMap(map);
    marker.on('click',function(e){
      infowindow.open(map,e.target.getPosition());
    })
    AMap.plugin('AMap.InfoWindow',function(){
       infowindow = new AMap.InfoWindow({
        content: '<div class="info-title">驾校地址</div><div class="info-content">'+decodeURIComponent(area_str)+'</div>',
        offset: new AMap.Pixel(0, -35)
      });
      infowindow.open(map,[longitude, latitude]);
    })
    AMap.plugin(['AMap.ToolBar','AMap.Scale'],function(){
        var toolBar = new AMap.ToolBar();
        var scale = new AMap.Scale();
        map.addControl(toolBar);
        map.addControl(scale);
    })
    
   </script>
    <script type="text/javascript" src="https://webapi.amap.com/demos/js/liteToolbar.js"></script>
  </body>
</html>